/**
 * AgentsStockholderService.java
 * Copyright(C) 1949++ 中华人民共和国
 * 深圳市盛开互联网金融顾问有限公司.
 * All rights reserved.
 * E-mail:server@skjr.net
 * SKDate:2017-11-16 17:28:58
 */
package com.huamao.zh.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.huamao.zh.base.PageWrapper;
import com.huamao.zh.mapper.AgentsStockholderMapper;
import com.huamao.zh.model.SktAgentsStockholder;
import com.huamao.zh.service.AgentsStockholderService;

@Service
@Transactional
public class AgentsStockholderServiceImpl implements AgentsStockholderService {

	@Autowired
	private AgentsStockholderMapper agentsStockholderMapper;

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public SktAgentsStockholder add(SktAgentsStockholder agentsStockholder) throws Exception {
		agentsStockholderMapper.add(agentsStockholder);
		return agentsStockholder;
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public SktAgentsStockholder addSelective(SktAgentsStockholder agentsStockholder) throws Exception {
		agentsStockholderMapper.addSelective(agentsStockholder);
		return agentsStockholder;
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public int delete(Map<String, Object> map) {
		return agentsStockholderMapper.delete(map);
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public int update(SktAgentsStockholder agentsStockholder) throws Exception {
		return agentsStockholderMapper.update(agentsStockholder);
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public int updateSelective(SktAgentsStockholder agentsStockholder) throws Exception {
		return agentsStockholderMapper.updateSelective(agentsStockholder);
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public SktAgentsStockholder get(Integer shId) {
		SktAgentsStockholder agentsStockholder = agentsStockholderMapper.get(shId);
		return agentsStockholder;
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public PageWrapper<SktAgentsStockholder> search(PageWrapper<SktAgentsStockholder> pageWrapper) {
		List<SktAgentsStockholder> agentsStockholders = agentsStockholderMapper.search(pageWrapper);
		pageWrapper.setList(agentsStockholders);
		return pageWrapper;
	}

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	public List<SktAgentsStockholder> queryList(Map<String, Object> map) {
		return agentsStockholderMapper.queryList(map);
	}

	@Override
	public List<SktAgentsStockholder> getByAgentId(int agentId) {
		return agentsStockholderMapper.getByAgentId(agentId);
	}
}